package com.ruoyi.system.contrat.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 合同管理对象 pb_contract
 * 
 * @author ruoyi
 * @date 2025-03-18
 */
public class Contract extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 自增主键，区块链存证时作为交易序列号 */
    @Excel(name = "交易序列号")
    private String ID;

    /** 合同号 */
    @Excel(name = "合同号", readConverterExp = "需=添加唯一约束")
    private String contractNo;

    /** 合同类型，关联字典表contract_type(id) */
    @Excel(name = "合同类型，关联字典表contract_type(id)")
    private String contractType;

    /** 合同甲方 */
    @Excel(name = "合同甲方")
    private String partyA;

    /** 合同乙方 */
    @Excel(name = "合同乙方")
    private String partyB;

    /** 合同状态枚举值：DRAFT-草案, APPROVING-审批中, EFFECTIVE-生效, TERMINATED-终止 */
    @Excel(name = "合同状态枚举值：DRAFT-草案, APPROVING-审批中, EFFECTIVE-生效, TERMINATED-终止")
    private String CSTATUS;

    /** 适用范围 */
    @Excel(name = "使用范围")
    private String applyArea;

    /** 签订时间（需与区块链时间戳同步） */
    @Excel(name = "签订时间", readConverterExp = "需=与区块链时间戳同步")
    private Date signDate;

    /** 生效时间（长期合同） */
    @Excel(name = "生效时间", readConverterExp = "长=期合同")
    private Date effectDate;

    /** 中止时间（长期合同） */
    @Excel(name = "中止时间", readConverterExp = "长=期合同")
    private Date termiDate;

    /** 作废时间（需记录区块链作废交易哈希） */
    @Excel(name = "作废时间", readConverterExp = "需=记录区块链作废交易哈希")
    private Date abolishDate;

    /** 到验号（单船合同），格式：船舶代码+到港日期 */
    @Excel(name = "到验号", readConverterExp = "单=船合同")
    private String UNIQUECODE;

    /** 船名（需与船舶登记系统同步） */
    @Excel(name = "船名", readConverterExp = "需=与船舶登记系统同步")
    private String shipName;

    /** 公司ID（外键关联company表区块链地址字段） */
    @Excel(name = "公司ID", readConverterExp = "外=键关联company表区块链地址字段")
    private Long comId;

    /** 原文件 */
    @Excel(name = "原文件")
    private String contractFile;

    public void setID(String ID) 
    {
        this.ID = ID;
    }

    public String getID() 
    {
        return ID;
    }

    public void setContractNo(String contractNo) 
    {
        this.contractNo = contractNo;
    }

    public String getContractNo() 
    {
        return contractNo;
    }

    public void setContractType(String contractType)
    {
        this.contractType = contractType;
    }

    public String getContractType()
    {
        return contractType;
    }

    public void setPartyA(String partyA) 
    {
        this.partyA = partyA;
    }

    public String getPartyA() 
    {
        return partyA;
    }

    public void setPartyB(String partyB) 
    {
        this.partyB = partyB;
    }

    public String getPartyB() 
    {
        return partyB;
    }

    public void setCSTATUS(String CSTATUS) 
    {
        this.CSTATUS = CSTATUS;
    }

    public String getCSTATUS() 
    {
        return CSTATUS;
    }

    public void setApplyArea(String applyArea) 
    {
        this.applyArea = applyArea;
    }

    public String getApplyArea() 
    {
        return applyArea;
    }

    public void setSignDate(Date signDate) 
    {
        this.signDate = signDate;
    }

    public Date getSignDate() 
    {
        return signDate;
    }

    public void setEffectDate(Date effectDate) 
    {
        this.effectDate = effectDate;
    }

    public Date getEffectDate() 
    {
        return effectDate;
    }

    public void setTermiDate(Date termiDate) 
    {
        this.termiDate = termiDate;
    }

    public Date getTermiDate() 
    {
        return termiDate;
    }

    public void setAbolishDate(Date abolishDate) 
    {
        this.abolishDate = abolishDate;
    }

    public Date getAbolishDate() 
    {
        return abolishDate;
    }

    public void setUNIQUECODE(String UNIQUECODE) 
    {
        this.UNIQUECODE = UNIQUECODE;
    }

    public String getUNIQUECODE() 
    {
        return UNIQUECODE;
    }

    public void setShipName(String shipName) 
    {
        this.shipName = shipName;
    }

    public String getShipName() 
    {
        return shipName;
    }

    public void setComId(Long comId) 
    {
        this.comId = comId;
    }

    public Long getComId() 
    {
        return comId;
    }

    public String getContractFile()
    {
        return contractFile;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("ID", getID())
            .append("contractNo", getContractNo())
            .append("contractType", getContractType())
            .append("partyA", getPartyA())
            .append("partyB", getPartyB())
            .append("CSTATUS", getCSTATUS())
            .append("applyArea", getApplyArea())
            .append("signDate", getSignDate())
            .append("effectDate", getEffectDate())
            .append("termiDate", getTermiDate())
            .append("abolishDate", getAbolishDate())
            .append("UNIQUECODE", getUNIQUECODE())
            .append("shipName", getShipName())
            .append("comId", getComId())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .append("contractFile", getContractFile())
           // .append("REMARK", getREMARK())
            .toString();
    }

}
